/* 现代风格问答系统界面样式 - 玻璃拟态效果版 */

/* 全局样式变量 */
:root {
  --primary-color: #4361ee;
  --primary-hover: #3a0ca3;
  --secondary-color: #4cc9f0;
  --success-color: #4895ef;
  --danger-color: #f72585;
  --warning-color: #ffbe0b;
  --text-primary: #2b2d42;
  --text-secondary: #6c757d;
  --text-light: #f8f9fa;
  --background-light: #f8f9fa;
  --background-white: #ffffff;
  --border-color: #e9ecef;
  --shadow-light: 0 2px 8px rgba(0,0,0,0.08);
  --shadow-medium: 0 4px 16px rgba(0,0,0,0.12);
  --shadow-heavy: 0 8px 32px rgba(0,0,0,0.16);
  --shadow-soft: 0 2px 6px rgba(0,0,0,0.06);
  --border-radius: 12px;
  --transition-base: all 0.3s ease;
  
  /* 玻璃拟态效果变量 */
  --glass-bg: rgba(255, 255, 255, 0.7);
  --glass-bg-dark: rgba(43, 45, 66, 0.7);
  --glass-border: rgba(255, 255, 255, 0.3);
  --glass-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  --glass-backdrop: blur(10px);
}

/* 全局样式设置 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', 'Microsoft YaHei', -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: var(--background-light);
  color: var(--text-primary);
  line-height: 1.7;
  /* 添加渐变背景增强玻璃效果 */
  background-image: 
    radial-gradient(circle at 20% 80%, rgba(67, 97, 238, 0.05) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(76, 201, 240, 0.05) 0%, transparent 50%);
  background-attachment: fixed;
}

/* 头部样式强化 - 玻璃拟态效果 */
header {
  background: rgba(67, 97, 238, 0.8);
  background-image: linear-gradient(135deg, rgba(67, 97, 238, 0.8), rgba(76, 201, 240, 0.8));
  backdrop-filter: var(--glass-backdrop);
  border-bottom: 1px solid var(--glass-border);
  padding: 1.5rem 2rem;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--glass-shadow);
}

.header-content {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 1.8rem;
  font-weight: 700;
  color: white;
  text-decoration: none;
  letter-spacing: 0.5px;
  text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.nav-links {
  display: flex;
  gap: 1rem;
}

.nav-links a {
  font-weight: 500;
  padding: 0.75rem 1.25rem;
  border-radius: 25px;
  transition: var(--transition-base);
  background: rgba(255,255,255,0.15);
  backdrop-filter: var(--glass-backdrop);
  border: 1px solid rgba(255,255,255,0.2);
  color: white;
  text-decoration: none;
}

.nav-links a:hover {
  background-color: rgba(255,255,255,0.3);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

/* 容器样式优化 */
.container {
  max-width: 1200px;
  margin: 2.5rem auto;
  padding: 0 1.5rem;
}

/* 卡片样式美化 - 玻璃拟态效果 */
.card {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-backdrop);
  border-radius: var(--border-radius);
  box-shadow: var(--glass-shadow);
  padding: 2.5rem;
  margin-bottom: 2rem;
  transition: var(--transition-base);
  border: 1px solid var(--glass-border);
}

.card:hover {
  box-shadow: var(--shadow-medium);
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.85);
}

/* 按钮样式美化 - 玻璃拟态效果 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  transition: var(--transition-base);
  min-width: 100px;
  height: 44px;
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(255, 255, 255, 0.2);
  opacity: 0;
  transform: translateY(100%);
  transition: var(--transition-base);
  z-index: -1;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.15);
}

.btn:hover::before {
  opacity: 1;
  transform: translateY(0);
}

.btn:active {
  transform: translateY(0);
}

/* 玻璃拟态按钮 */
.btn-glass {
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border);
  color: var(--text-primary);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.btn-glass:hover {
  background: rgba(255, 255, 255, 0.3);
  box-shadow: 0 6px 16px rgba(0,0,0,0.15);
}

/* 主按钮 */
.btn-primary {
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  color: white;
  box-shadow: 0 4px 12px rgba(67, 97, 238, 0.3);
}

.btn-primary:hover {
  background: linear-gradient(135deg, var(--primary-hover), var(--secondary-color));
  box-shadow: 0 6px 16px rgba(67, 97, 238, 0.4);
}

/* 描边按钮 */
.btn-outline {
  background: transparent;
  border: 2px solid var(--primary-color);
  color: var(--primary-color);
}

.btn-outline:hover {
  background: var(--primary-color);
  color: white;
  box-shadow: 0 4px 12px rgba(67, 97, 238, 0.3);
}

/* 危险按钮 */
.btn-danger {
  background: linear-gradient(135deg, var(--danger-color), #ff758f);
  color: white;
  box-shadow: 0 4px 12px rgba(247, 37, 133, 0.3);
}

.btn-danger:hover {
  box-shadow: 0 6px 16px rgba(247, 37, 133, 0.4);
}

/* 成功按钮 */
.btn-success {
  background: linear-gradient(135deg, var(--success-color), #4cc9f0);
  color: white;
  box-shadow: 0 4px 12px rgba(72, 149, 239, 0.3);
}

.btn-success:hover {
  box-shadow: 0 6px 16px rgba(72, 149, 239, 0.4);
}

/* 页面标题样式 */
.page-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2.5rem;
  gap: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-color);
}

.page-header h2 {
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* 搜索栏样式 */
.search-bar {
  display: flex;
  gap: 1rem;
  align-items: center;
  flex-wrap: wrap;
}

.search-bar input {
  padding: 0.75rem 1.25rem;
  border: 2px solid var(--border-color);
  border-radius: 12px;
  font-size: 1rem;
  min-width: 240px;
  transition: var(--transition-base);
  background: var(--glass-bg);
  backdrop-filter: var(--glass-backdrop);
}

.search-bar input:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(67, 97, 238, 0.2);
}

/* 问题列表容器 - 玻璃拟态效果 */
.question-list-container {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-backdrop);
  border-radius: var(--border-radius);
  box-shadow: var(--glass-shadow);
  overflow: hidden;
  border: 1px solid var(--glass-border);
  padding: 1rem;
  margin-bottom: 2rem;
}

/* 问题项样式美化 */
.question-item {
  padding: 1.5rem;
  border-bottom: 1px solid var(--border-color);
  transition: var(--transition-base);
  cursor: pointer;
  border-radius: 12px;
  margin-bottom: 1rem;
  background: rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(5px);
}

.question-item:hover {
  background-color: rgba(255, 255, 255, 0.8);
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.1);
}

.question-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.question-header {
  margin-bottom: 1rem;
}

.question-title {
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--primary-color);
  margin-bottom: 0.75rem;
  transition: var(--transition-base);
  line-height: 1.4;
  position: relative;
  padding-left: 1rem;
}

.question-title::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 60%;
  background: linear-gradient(to bottom, var(--primary-color), var(--secondary-color));
  border-radius: 2px;
}

.question-title:hover {
  color: var(--primary-hover);
}

.question-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
}

.question-content {
  font-size: 1rem;
  color: var(--text-primary);
  margin-bottom: 1.5rem;
  line-height: 1.6;
  padding: 1rem;
  background: rgba(255, 255, 255, 0.3);
  border-radius: 8px;
  border-left: 3px solid var(--secondary-color);
}

.question-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  align-items: center;
  justify-content: space-between;
}

.question-reward {
  display: inline-flex;
  align-items: center;
  background: linear-gradient(135deg, rgba(247, 37, 133, 0.2), rgba(255, 117, 143, 0.2));
  color: var(--danger-color);
  font-weight: 600;
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-size: 0.95rem;
  border: 1px solid rgba(247, 37, 133, 0.3);
}

.question-reward:hover {
  background: linear-gradient(135deg, rgba(247, 37, 133, 0.3), rgba(255, 117, 143, 0.3));
}

.question-view-count,
.question-answer-count {
  display: inline-flex;
  align-items: center;
  color: var(--text-secondary);
  font-size: 0.9rem;
  background: rgba(255, 255, 255, 0.4);
  padding: 0.25rem 0.75rem;
  border-radius: 15px;
  border: 1px solid var(--glass-border);
}

/* 分页样式美化 */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  margin: 2rem 0;
  padding: 1rem;
}

.pagination button {
  padding: 0.75rem 1.25rem;
  border: 1px solid var(--border-color);
  background-color: var(--background-white);
  border-radius: 8px;
  cursor: pointer;
  font-weight: 500;
  transition: var(--transition-base);
  min-width: 40px;
}

.pagination button:hover:not(.disabled) {
  background-color: var(--primary-color);
  color: white;
  border-color: var(--primary-color);
  transform: translateY(-1px);
}

.pagination button.active {
  background-color: var(--primary-color);
  color: white;
  border-color: var(--primary-color);
  font-weight: 600;
}

.pagination button.disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* 模态框样式美化 - 玻璃拟态效果 */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0,0,0,0.4);
  backdrop-filter: blur(10px);
  transition: var(--transition-base);
}

.modal-content {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-backdrop);
  margin: 3rem auto;
  padding: 2rem;
  border: 1px solid var(--glass-border);
  width: 95%;
  max-width: 800px;
  max-height: 90vh;
  overflow-y: auto;
  border-radius: var(--border-radius);
  box-shadow: var(--glass-shadow);
  animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.close {
  color: var(--text-secondary);
  float: right;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
  transition: var(--transition-base);
}

.close:hover {
  color: var(--danger-color);
  transform: rotate(90deg);
}

/* 问题详情样式 */
.question-detail {
  padding-bottom: 2rem;
  margin-bottom: 2rem;
  border-bottom: 2px solid var(--border-color);
}

.question-detail h2 {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 1.5rem;
  line-height: 1.4;
}

.question-detail .question-content {
  font-size: 1.1rem;
  line-height: 1.8;
  white-space: pre-wrap;
  margin-bottom: 1.5rem;
}

.question-actions {
  display: flex;
  gap: 1rem;
  margin-top: 1.5rem;
}

/* 回答区域样式 */
.answers-section {
  margin-top: 2.5rem;
  padding: 1.5rem;
  background: var(--glass-bg);
  backdrop-filter: var(--glass-backdrop);
  border-radius: var(--border-radius);
  border: 1px solid var(--glass-border);
}

.answers-section h3 {
  font-size: 1.4rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  color: var(--text-primary);
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-color);
}

/* 回答项样式美化 - 玻璃拟态效果 */
.answer-item {
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(5px);
  border-radius: var(--border-radius);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  border: 1px solid var(--glass-border);
  transition: var(--transition-base);
  position: relative;
  overflow: hidden;
}

.answer-item:hover {
  box-shadow: var(--shadow-medium);
  transform: translateY(-3px);
  background: rgba(255, 255, 255, 0.8);
}

/* 接受的回答样式 */
.answer-item.accepted {
  background: linear-gradient(135deg, rgba(72, 149, 239, 0.2), rgba(76, 201, 240, 0.1));
  border: 2px solid var(--success-color);
  position: relative;
}

.answer-item.accepted::before {
  content: '✓';
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--success-color), #4cc9f0);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  box-shadow: 0 4px 12px rgba(72, 149, 239, 0.3);
}

/* 回答项装饰效果 */
.answer-item::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
  opacity: 0;
  transition: var(--transition-base);
}

.answer-item:hover::after {
  opacity: 1;
}

.answer-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-bottom: 1rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.accepted-badge {
  background-color: var(--success-color);
  color: white;
  padding: 0.25rem 0.75rem;
  border-radius: 15px;
  font-weight: 500;
}

.answer-content {
  font-size: 1rem;
  line-height: 1.7;
  white-space: pre-wrap;
  margin-bottom: 1rem;
}

.answer-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 1rem;
}

/* 回答表单样式 */
.answer-form {
  background-color: #f8f9fa;
  border-radius: var(--border-radius);
  padding: 1.5rem;
  margin-top: 2rem;
  border: 1px solid var(--border-color);
}

.answer-form h4 {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.answer-form textarea {
  min-height: 120px;
  padding: 1rem;
  border: 2px solid var(--border-color);
  border-radius: 8px;
  font-size: 1rem;
  resize: vertical;
  transition: var(--transition-base);
  font-family: inherit;
  line-height: 1.5;
}

.answer-form textarea:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(67, 97, 238, 0.1);
}

.answer-form button {
  margin-top: 1rem;
}

/* 表单样式优化 - 玻璃拟态效果 */
.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
  font-weight: 500;
  font-size: 0.95rem;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.85rem 1.1rem;
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius);
  background: var(--glass-bg);
  backdrop-filter: var(--glass-backdrop);
  font-size: 1rem;
  transition: var(--transition-base);
  font-family: inherit;
  color: var(--text-primary);
  box-shadow: var(--shadow-light);
}

.form-group input::placeholder,
.form-group textarea::placeholder,
.form-group select::placeholder {
  color: var(--text-secondary);
  opacity: 0.7;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(67, 97, 238, 0.2);
  background: rgba(255, 255, 255, 0.8);
}

.form-group textarea {
  resize: vertical;
  min-height: 150px;
  line-height: 1.6;
}

/* 提示框样式 */
.alert {
  padding: 1rem 1.5rem;
  margin-bottom: 1.5rem;
  border-radius: 8px;
  border-left: 4px solid;
  transition: var(--transition-base);
}

.alert-success {
  background-color: rgba(72, 149, 239, 0.1);
  color: var(--success-color);
  border-color: var(--success-color);
}

.alert-danger {
  background-color: rgba(247, 37, 133, 0.1);
  color: var(--danger-color);
  border-color: var(--danger-color);
}

/* 用户信息样式 - 玻璃拟态效果 */
.user-info-header {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  margin-bottom: 2.5rem;
  padding: 2rem;
  background: var(--glass-bg);
  backdrop-filter: var(--glass-backdrop);
  border-radius: var(--border-radius);
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
}

.user-avatar {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  margin-right: 1.5rem;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 3rem;
  color: white;
  position: relative;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(67, 97, 238, 0.3);
  transition: var(--transition-base);
  flex-shrink: 0;
  overflow: hidden;
  border: 3px solid rgba(255, 255, 255, 0.5);
}

.user-avatar:hover {
  transform: scale(1.05);
  box-shadow: var(--shadow-medium);
  border-color: rgba(255, 255, 255, 0.8);
}

/* 用户基本信息样式 */
.user-basic-info {
  flex: 1;
  min-width: 250px;
}

.user-basic-info h2 {
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

.user-basic-info p {
  font-size: 1rem;
  color: var(--text-secondary);
  margin-bottom: 1rem;
  line-height: 1.6;
}

/* 用户金币信息样式 */
.user-coin-info {
  background: rgba(255, 190, 11, 0.08);
  padding: 1.5rem;
  border-radius: var(--border-radius);
  border: 1px solid rgba(255, 190, 11, 0.2);
  min-width: 200px;
}

.coin-balance {
  margin-bottom: 1rem;
  text-align: center;
}

.coin-label {
  display: block;
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 0.25rem;
}

.coin-amount {
  display: block;
  font-size: 2rem;
  font-weight: 700;
  color: var(--warning-color);
  text-shadow: 0 2px 4px rgba(255, 190, 11, 0.2);
}

/* 用户活动标签页样式 */
.user-activity-tabs {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.5rem;
  padding: 0.5rem;
  background: var(--glass-bg);
  backdrop-filter: var(--glass-backdrop);
  border-radius: 12px;
  border: 1px solid var(--glass-border);
}

.tab-btn {
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 8px;
  background: transparent;
  cursor: pointer;
  font-weight: 500;
  color: var(--text-secondary);
  transition: var(--transition-base);
  position: relative;
}

.tab-btn:hover {
  background: rgba(255, 255, 255, 0.5);
  color: var(--text-primary);
}

.tab-btn.active {
  background: rgba(67, 97, 238, 0.1);
  color: var(--primary-color);
  font-weight: 600;
}

.tab-btn.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 40px;
  height: 3px;
  background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
  border-radius: 3px;
}

/* 用户活动内容样式 */
.user-activity-content {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-backdrop);
  border-radius: var(--border-radius);
  border: 1px solid var(--glass-border);
  padding: 2rem;
}

/* 标签样式 - 玻璃拟态效果 */
.tag {
  display: inline-block;
  padding: 0.3rem 1rem;
  background: var(--glass-bg);
  backdrop-filter: var(--glass-backdrop);
  color: var(--primary-color);
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 500;
  margin-right: 0.5rem;
  margin-bottom: 0.5rem;
  transition: var(--transition-base);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-soft);
}

.tag:hover {
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  color: white;
  transform: translateY(-1px);
  box-shadow: var(--shadow-medium);
}

/* 徽章样式 - 玻璃拟态效果 */
.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.25rem 0.75rem;
  background: linear-gradient(135deg, var(--danger-color), #e57373);
  color: white;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(244, 67, 54, 0.3);
  transition: var(--transition-base);
}

.badge:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(244, 67, 54, 0.4);
}

.badge.success {
  background: linear-gradient(135deg, var(--success-color), #66bb6a);
  box-shadow: 0 2px 8px rgba(76, 175, 80, 0.3);
}

.badge.success:hover {
  box-shadow: 0 4px 12px rgba(76, 175, 80, 0.4);
}

.badge.info {
  background: linear-gradient(135deg, var(--primary-color), #7986cb);
  box-shadow: 0 2px 8px rgba(67, 97, 238, 0.3);
}

.badge.info:hover {
  box-shadow: 0 4px 12px rgba(67, 97, 238, 0.4);
}

.badge.warning {
  background: linear-gradient(135deg, var(--warning-color), #ffb74d);
  box-shadow: 0 2px 8px rgba(255, 190, 11, 0.3);
}

.badge.warning:hover {
  box-shadow: 0 4px 12px rgba(255, 190, 11, 0.4);
}

/* 加载动画 */
.loading-container {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 3rem 0;
}

.loading {
  display: inline-block;
  width: 24px;
  height: 24px;
  border: 3px solid var(--glass-border);
  border-top: 3px solid var(--primary-color);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* 空状态样式 - 玻璃拟态效果 */
.empty-state {
  text-align: center;
  padding: 4rem 2rem;
  color: var(--text-secondary);
  background: var(--glass-bg);
  backdrop-filter: var(--glass-backdrop);
  border-radius: var(--border-radius);
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
}

.empty-state i {
  font-size: 4rem;
  margin-bottom: 1.5rem;
  opacity: 0.7;
  color: var(--primary-color);
  transition: var(--transition-base);
}

.empty-state:hover i {
  transform: scale(1.1);
  opacity: 1;
}

.empty-state h3 {
  margin-bottom: 0.75rem;
  color: var(--text-primary);
  font-size: 1.3rem;
}

.empty-state p {
  max-width: 400px;
  margin: 0 auto 1.5rem;
  line-height: 1.6;
  font-size: 1rem;
}

.empty-state .btn {
  margin-top: 0.5rem;
}

/* 工具提示样式 - 玻璃拟态效果 */
.tooltip {
  position: relative;
  cursor: help;
}

.tooltip::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: var(--glass-bg-dark);
  backdrop-filter: var(--glass-backdrop);
  color: white;
  padding: 0.5rem 0.75rem;
  border-radius: var(--border-radius);
  font-size: 0.85rem;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition-base);
  margin-bottom: 8px;
  z-index: 1000;
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-medium);
  line-height: 1.4;
}

.tooltip::before {
  content: '';
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 5px solid transparent;
  border-top-color: var(--glass-border);
  opacity: 0;
  visibility: hidden;
  transition: var(--transition-base);
  z-index: 1000;
  margin-bottom: 3px;
}

.tooltip:hover::after,
.tooltip:hover::before {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(-3px);
}

/* 页脚样式 - 玻璃拟态效果 */
footer {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-backdrop);
  padding: 2rem 0;
  border-top: 1px solid var(--glass-border);
  margin-top: 3rem;
  box-shadow: 0 -5px 15px rgba(0, 0, 0, 0.05);
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 2rem;
}

.footer-logo {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary-color);
  text-shadow: 0 2px 4px rgba(67, 97, 238, 0.2);
}

.footer-links {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.footer-links a {
  color: var(--text-secondary);
  transition: var(--transition-base);
  position: relative;
  padding: 0.25rem 0;
}

.footer-links a:hover {
  color: var(--primary-color);
}

.footer-links a::after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: 0;
  left: 0;
  background-color: var(--primary-color);
  transition: width 0.3s ease;
}

.footer-links a:hover::after {
  width: 100%;
}

.footer-copyright {
  width: 100%;
  text-align: center;
  padding-top: 1.5rem;
  margin-top: 1.5rem;
  border-top: 1px solid var(--glass-border);
  color: var(--text-secondary);
  font-size: 0.9rem;
}

/* 两栏布局样式 */
.home-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 2rem;
  margin: 0 auto;
  max-width: 1400px;
  width: 100%;
  padding: 0 1rem;
}

/* 主问题区域样式 */
.main-questions-area {
  background: rgba(255, 255, 255, 0.8);
  border-radius: 16px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border);
  padding: 1.5rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.05);
  height: fit-content;
  position: sticky;
  top: 2rem;
}

.sidebar-header h2 {
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--glass-border);
}

.scrollable-questions {
  max-height: 500px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--primary-color) rgba(0, 0, 0, 0.05);
}

.scrollable-questions::-webkit-scrollbar {
  width: 6px;
}

.scrollable-questions::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.05);
  border-radius: 10px;
}

.scrollable-questions::-webkit-scrollbar-thumb {
  background: var(--primary-color);
  border-radius: 10px;
  transition: background-color 0.2s ease;
}

.scrollable-questions::-webkit-scrollbar-thumb:hover {
  background: var(--primary-hover);
}

/* 中间栏样式已移除，现在热门问题区域占据左侧和中间位置 */

/* 排行榜标签页样式 */
.ranking-tabs {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.tab-btn {
  padding: 0.5rem 1rem;
  border: 1px solid var(--glass-border);
  background: rgba(255, 255, 255, 0.6);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.tab-btn:hover {
  background: rgba(255, 255, 255, 0.8);
  color: var(--text-primary);
  transform: translateY(-1px);
}

.tab-btn.active {
  background: var(--primary-color);
  color: white;
  border-color: var(--primary-color);
  box-shadow: 0 4px 12px rgba(67, 97, 238, 0.2);
}

/* 排行榜项样式 */
.featured-question-item {
  padding: 1rem;
  margin-bottom: 0.75rem;
  border-radius: 12px;
  border: 1px solid var(--glass-border);
  transition: all 0.3s ease;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.featured-question-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.08);
}

.featured-question-rank {
  position: absolute;
  top: 10px;
  left: 10px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--primary-color);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: bold;
}

/* 前三名特殊样式 */
.featured-question-item:nth-child(1) .featured-question-rank {
  background: #ffd700;
  box-shadow: 0 0 0 2px rgba(255, 215, 0, 0.3);
}

.featured-question-item:nth-child(2) .featured-question-rank {
  background: #c0c0c0;
  box-shadow: 0 0 0 2px rgba(192, 192, 192, 0.3);
}

.featured-question-item:nth-child(3) .featured-question-rank {
  background: #cd7f32;
  box-shadow: 0 0 0 2px rgba(205, 127, 50, 0.3);
}

.featured-question-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0.25rem 0;
  padding-left: 35px;
  transition: color 0.2s ease;
}

.featured-question-title:hover {
  color: var(--primary-color);
}

.featured-question-meta {
  display: flex;
  gap: 1rem;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.featured-question-footer {
  display: flex;
  gap: 1rem;
  font-size: 0.85rem;
  padding-top: 0.5rem;
  border-top: 1px solid var(--glass-border);
}

.featured-question-reward {
  color: #ff9800;
  font-weight: 500;
}

.featured-question-view-count {
  color: #2196f3;
}

.featured-question-answer-count {
  color: #4caf50;
}

/* 右侧栏样式 */
.right-sidebar {
  background: rgba(255, 255, 255, 0.8);
  border-radius: 16px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border);
  padding: 1.5rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.05);
  height: fit-content;
  position: sticky;
  top: 2rem;
}

.sidebar-content h2 {
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

.sidebar-content p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
}

.sidebar-buttons {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 2rem;
}

.sidebar-actions {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.action-section {
  padding: 1rem;
  background: rgba(255, 255, 255, 0.5);
  border-radius: 12px;
  border: 1px solid var(--glass-border);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.action-section:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.action-section h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

.action-section p {
  color: var(--text-secondary);
  margin-bottom: 1rem;
  font-size: 0.9rem;
  line-height: 1.5;
}

.action-section .btn {
  width: 100%;
}

/* 响应式设计 */
@media (max-width: 1200px) {
  .header-content {
    max-width: 1100px;
  }
  
  .container {
    max-width: 1100px;
  }
  
  .home-layout {
    grid-template-columns: 1fr 280px;
  }
}

@media (max-width: 992px) {
  .header-content {
    max-width: 900px;
  }
  
  .container {
    max-width: 900px;
  }
  
  .quick-actions {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .home-layout {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .main-questions-area,
  .right-sidebar {
    position: relative;
    top: 0;
  }
  
  .scrollable-questions {
    max-height: 300px;
  }
  
  .sidebar-actions {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
  }
}

@media (max-width: 768px) {
  .container {
    padding: 1rem;
    max-width: 100%;
  }
  
  .header {
    padding: 1rem;
  }
  
  .header-content {
    flex-direction: column;
    gap: 1rem;
    max-width: 100%;
  }
  
  .nav-links {
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
  }
  
  .nav-links a {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
  }
  
  .card {
    padding: 1.5rem;
  }
  
  .search-bar {
    flex-direction: column;
    gap: 1rem;
  }
  
  .search-bar input {
    width: 100%;
  }
  
  .quick-actions {
    grid-template-columns: 1fr;
  }
  
  .sidebar-actions {
    grid-template-columns: 1fr;
  }
  
  .question-item {
    padding: 1.5rem;
  }
  
  .question-item-header {
    flex-direction: column;
    gap: 0.5rem;
    align-items: flex-start;
  }
  
  .pagination {
    flex-wrap: wrap;
    gap: 0.5rem;
  }
  
  .answer-item {
    padding: 1.5rem;
  }
  
  .user-info-header {
    flex-direction: column;
    gap: 1.5rem;
    text-align: center;
  }
  
  .user-avatar {
    margin-right: 0;
  }
  
  .user-activity-tabs {
    flex-wrap: wrap;
    justify-content: center;
  }
  
  .tab-btn {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
  }
  
  .user-activity-content {
    padding: 1.5rem;
  }
}

@media (max-width: 480px) {
  .header {
    padding: 0.75rem;
  }
  
  .logo {
    font-size: 1.3rem;
  }
  
  .nav-links a {
    padding: 0.5rem 0.8rem;
    font-size: 0.85rem;
  }
  
  .page-header h2 {
    font-size: 1.6rem;
  }
  
  .btn {
    padding: 0.6rem 1.2rem;
    font-size: 0.9rem;
  }
  
  .question-title {
    font-size: 1.2rem;
  }
  
  .user-info-header {
    padding: 1.5rem;
  }
  
  .user-avatar {
    width: 100px;
    height: 100px;
    font-size: 2.5rem;
  }
  
  .user-basic-info h2 {
    font-size: 1.5rem;
  }
  
  .coin-amount {
    font-size: 1.8rem;
  }
  
  .modal-content {
    margin: 1rem;
    width: calc(100% - 2rem);
  }
}